package struct.decorator.example;

/**
 * 服饰类，等同于Decorator
 */
public class Finery implements ICharacter{

    protected ICharacter component;

    public void decorate(ICharacter component) {
        this.component = component;
    }

    @Override
    public void show() {
        if (this.component != null) {
            component.show();
        }
    }
}
